<?php

class _index
{
    public function index()
    {
        View::display('index');
    }

    //生成图片验证码
    public function vcode()
    {
        $width = Request::Get('w', 80);
        $height = Request::Get('h', 40);
        $code=new ValidationCode($width, $height, 4);
        $code->showImage();
        $_SESSION['reg_vcode'] = $code->getCheckCode();
        $_SESSION['reg_vcode_lasttime'] = REQUEST_TIME;
//        FileLog::ini('error')->info([__METHOD__,REQUEST_TIME, $_SESSION]);
    }
}
